package org.apache.flink.runtime.metrics.scope;

/**
 * The scope format for the {@link org.apache.flink.runtime.metrics.groups.ResourceProviderMetricGroup}.
 */
public class ResoruceProviderScopeFormat extends ScopeFormat {

    public ResoruceProviderScopeFormat(String format) {
        super(format, null, new String[] {SCOPE_HOST, SCOPE_TASKMANAGER_ID});
    }

    public String[] formatScope(String hostname, String taskManagerId) {
        final String[] template = copyTemplate();
        final String[] values = {hostname, taskManagerId};
        return bindVariables(template, values);
    }
}
